package com.zl.easybuy.web;

import com.zl.easybuy.exc.EasyBuyExc;
import com.zl.easybuy.vo.ReaultVo;
import com.zl.easybuy.vo.ResultCode;
import org.springframework.web.bind.annotation.ControllerAdvice;
import org.springframework.web.bind.annotation.ExceptionHandler;

@ControllerAdvice
public class EasybuyExceptionHandler {
    @ExceptionHandler
    public ReaultVo exc(EasyBuyExc e){
        return new ReaultVo(1002,e.getMessage());
    }
}
